package code.tools.traceLog
{
	import code.tools.traceLog.hexagonstar.util.debug.Debug;
	import code.untils.GameConst;

	/**
	 * 统一trace 
	 * @author Yuri
	 * 
	 */
	public class TraceLog
	{
		/**
		 *是否打印 
		 */
		public static var isTrace:Boolean = true;
		/**
		 * 打印顺序
		 */
		private static var iTraceCount:int;
		/**
		 *显示打印 
		 * @param str
		 * @param prompt
		 * 
		 */
		public static function showTrace(message:*,prompt:String = "打印"):void{
			if(!isTrace) return;
			trace((++iTraceCount) + ":" + prompt + ":" + message.toString());
		}
		/**
		 * 是否通过工具打印
		 */
		public static function traceByTool(name:String, message:*):void{
			if(!GameConst.isTraceLogByTool) return;
			
			Debug.trace(name)
			Debug.delimiter();
			Debug.traceObj(message);
		}
	}
}